package com.example.administrator.capital;
import android.view.View;

import com.example.administrator.capital.base.BaseActivity;

import me.yokeyword.fragmentation.anim.DefaultHorizontalAnimator;
import me.yokeyword.fragmentation.anim.FragmentAnimator;

public class MainActivity extends BaseActivity {
    @Override
    public int getLayoutId() {
        return R.layout.activity_main;
    }
    @Override
    public void initView() {
        if (findFragment(MainFragment.class) == null) {
            loadRootFragment(R.id.fl_container, MainFragment.newInstance());
        }
    }
    @Override
    public void setListener() {
    }
    @Override
    public void setData() {
    }
    @Override
    public void onBackPressedSupport() {
        // 对于 4个类别的主Fragment内的回退back逻辑,已经在其onBackPressedSupport里各自处理了
        super.onBackPressedSupport();
    }
    @Override
    public FragmentAnimator onCreateFragmentAnimator() {
        // 设置横向动画
        return new DefaultHorizontalAnimator();
        // 设置竖向动画
//        return new_name DefaultVerticalAnimator();
        // 无动画
//        return new_name DefaultNoAnimator();
    }

    @Override
    public void onClick(View view) {

    }
}
